put card field "Time Increment" into timeIncrement1
put card field "Drop Height"*10 into dropHeight1
put card field "Cart Speed"*10 into cartSpeed1
put the hilite of button "Trace Ball Path" into trace1
end setParameters
-- part 1 (field)
-- low flags: 02
-- high flags: 0002
-- rect: left=272 top=65 right=82 bottom=312
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 3
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Cart Speed
-- part 3 (field)
-- low flags: 02
-- high flags: 0002
-- rect: left=272 top=85 right=102 bottom=312
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 3
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Drop Height
----- HyperTalk script -----
on closeField
get me
if it > 22 or it < 5 then
answer "That value must be between 5 and 22."
select line 1 of me
end if
end closefield
-- part 5 (field)
-- low flags: 02
-- high flags: 0002
-- rect: left=272 top=105 right=122 bottom=312
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 3
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Time Increment
-- part 6 (button)
-- low flags: 00
-- high flags: C005
-- rect: left=46 top=131 right=153 bottom=172
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Trace Ball Path
----- HyperTalk script -----
on mouseUp
set the hilite of me to not the hilite of me
end mouseUp
-- part 7 (field)
-- low flags: 81
-- high flags: 2004
-- rect: left=11 top=40 right=326 bottom=403
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 3
-- text size: 12
-- style flags: 256
-- line height: 16
-- part name: Help
-- part contents for card part 1
----- text -----
80
-- part contents for card part 3
----- text -----
20
-- part contents for card part 5
----- text -----
.01
-- part contents for background part 6
----- text -----
Changing values in the top half alters the path of the ball.
-- part contents for card part 7
----- text -----
The parameters below the gray bar are constants provided for your benefit. They may not be changed without altering the calculation scripts attached to the card.
The parameters listed above the bar are variable. To change any of them, drag across the box holding the value and type the new value. Pressing <return> will automatically select the value in the next field.
Any change in the controlled parameters will be reflected as a change in the outcome of the experiment. Feel free to play around.